Skip to content

tests(mark_sweep): add coverage for merged parity helpers#67

Merged
nekevss merged 1 commit intoboa-dev:mainfrom
Flamki:tests/gc-parity-helpers
Mar 30, 2026
Merged

tests(mark_sweep): add coverage for merged parity helpers#67
nekevss merged 1 commit intoboa-dev:mainfrom
Flamki:tests/gc-parity-helpers

Conversation

@Flamki
Copy link
Copy Markdown
Contributor

@Flamki Flamki commented Mar 27, 2026

This PR adds focused test coverage for the parity helper APIs that were merged from #64, #65, and #66.

Refs: #63

What this adds

  • mark_sweep tests for:
    • Gc::into_raw / Gc::from_raw round-trip identity and value stability
    • Gc::downcast / Gc::cast_unchecked parity behavior
    • WeakGc::upgrade liveness behavior before and after collection
  • Matching coverage in mark_sweep2 (mark_sweep_arena2) for the same helper set

Why

In #63, maintainer feedback called out that parity was in a good place but these newly added helpers still needed tests.

This PR keeps scope strictly to tests for those merged parity APIs.

Scope

  • tests only
  • no runtime or API behavior changes

Validation

  • cargo fmt --all -- --check
  • cargo test --workspace

Copy link
Copy Markdown
Member

@nekevss nekevss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, thanks!

@nekevss nekevss merged commit f717de6 into boa-dev:main Mar 30, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants